public class EmailClass
{
    public static void uniqueEmail(Email__c[] e)
    {
        for(Email__c em:e)
        {
            string temp = e[0].Name;
            integer emailCount =[select count() from Email__c where name=: temp];
            if(emailCount>0)
            {
                em.adderror('Email already exits');            
            }
        }        
    }
}